package com.example.zqh.pojo.params;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.example.zqh.pojo.Food;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @Author: zqh
 * @Date: 2022-09-14-18:44
 * @Description: food表上传es中的数据格式$
 */
@Data
@NoArgsConstructor
public class FoodPlus {


    private Integer id;


    private String name;


    private String ingredientList;


    private Double price;


    private String foodDesc;


    private String benefit;


    private String pic;


    private Integer shopId;


    private Integer foodType;

    private String suggestion;

    public FoodPlus(Food food){
        this.id = food.getId();
        this.name = food.getName();
        this.ingredientList = food.getIngredientList();
        this.price = food.getPrice();
        this.foodDesc = food.getFoodDesc();
        this.benefit = food.getBenefit();
        this.pic = food.getPic();
        this.shopId = food.getShopId();
        this.foodType = food.getFoodType();
        this.suggestion = food.getName();
    }
}
